package vis.items.visualItem;

import java.awt.Color;

import processing.core.PApplet;

public class MyLabel extends RectObject implements IVisualObject {
	private TextObject textObj;

	public MyLabel(PApplet root, IVisualObject parent) {
		super(root, parent);
		createTextObject();
	}

	private void createTextObject() {
		textObj = (TextObject) new TextObject(root, this);
		addChild(textObj);
	}

	public MyLabel text(String text) {
		textObj.text(text);
		return this;
	}

	public MyLabel textColor(Color textColor) {
		textObj.color(textColor);
		return this;
	}

	public MyLabel textPosition(int x, int y) {
		// TODO minhvv have to disable this feature beacause of errors on
		// position
		// textObj.at(x, y);
		return this;
	}

	@Override
	public void updateItself() {
		super.updateItself();
	}
}
